#ifndef DRIVE_SUBSYSTEM_H
#define DRIVE_SUBSYSTEM_H

#include "WPILib.h"
#include "RobotSubsystem.h"

class FrcDriveSubsystem : public RobotSubsystem
{
public:
	FrcDriveSubsystem();
	virtual ~FrcDriveSubsystem();
	virtual void DoRobotInit(void);
	virtual void DoTeleopInit(void);
	virtual void DoDisabledInit(void);
	virtual void DoTeleopPeriodic(void);
	virtual void DoDisabledPeriodic(void);
	virtual void DoAutonomousPeriodic(void);
	virtual void DoAutonomousInit(void);
	
	
	float LJX;
	float LJY;
	float RJX;
	void DriveByTime();
	void DriveByTimeReverse();
	double GetDriveTime();
	void SetTargetTimeInSeconds(double seconds);
	bool IsDriveByTimeFinished();
	void ResetTimer();
	Timer *m_driveTimer;
	

	
private:
	void FrcMecanumDrive(Joystick *js_left, Joystick *js_right);
	
	RobotDrive *m_frcDrive;
	
	Joystick *m_leftJoystick;
	Joystick *m_rightJoystick;
	
	Talon *m_leftFrontDriveMotor;
	Talon *m_leftRearDriveMotor;
	Talon *m_rightFrontDriveMotor;
	Talon *m_rightRearDriveMotor;
	
	double m_driveTimeTarget; 
	
	
};

#endif
